﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Microsoft.SilverlightMediaFramework.Plugins.DualMedia;
using Microsoft.SilverlightMediaFramework.Plugins.Progressive;

namespace Test.DualMedia
{
    public partial class MainPage : UserControl
    {
        public MainPage()
        {
            InitializeComponent();
            smf.MediaPluginRegistered += new EventHandler<Microsoft.SilverlightMediaFramework.Core.CustomEventArgs<Microsoft.SilverlightMediaFramework.Plugins.IMediaPlugin>>(smf_MediaPluginRegistered);
        }

        void smf_MediaPluginRegistered(object sender, Microsoft.SilverlightMediaFramework.Core.CustomEventArgs<Microsoft.SilverlightMediaFramework.Plugins.IMediaPlugin> e)
        {
            var S3DPlugin = e.Value as DualMediaPlugin;
            S3DPlugin.LeftSource = new ProgressiveMediaPlugin();
            S3DPlugin.RightSource = new ProgressiveMediaPlugin();
        }
    }
}
